package com.chainyoung.common.appcommon.entity;

import android.os.Parcel;
import android.os.Parcelable;

public class Version implements Parcelable {


    /**
     * enforce : 1
     * version : 1.0
     * newversion : 1.01
     * downloadurl : www.coinworldau.com/download
     * packagesize : 10241
     * upgradetext : 1、市场行情 2、消息中心
     */

    private String enforce;
    private int version_code;//最新版本号
    private String newversion;//新版本
    private String downloadurl;//新版本下载url
    private String packagesize;//app 大小
    private String upgradetext;//更新的详细信息
    private String md5;//md5 值


    protected Version(Parcel in) {
        enforce = in.readString();
        version_code = in.readInt();
        newversion = in.readString();
        downloadurl = in.readString();
        packagesize = in.readString();
        upgradetext = in.readString();
        md5 = in.readString();
    }


    public static final Creator<Version> CREATOR = new Creator<Version>() {
        @Override
        public Version createFromParcel(Parcel in) {
            return new Version(in);
        }

        @Override
        public Version[] newArray(int size) {
            return new Version[size];
        }
    };

    public String getNewversion() {
        return newversion;
    }

    public void setNewversion(String newversion) {
        this.newversion = newversion;
    }

    public String getDownloadurl() {
        return downloadurl;
    }

    public void setDownloadurl(String downloadurl) {
        this.downloadurl = downloadurl;
    }

    public String getPackagesize() {
        return packagesize;
    }

    public void setPackagesize(String packagesize) {
        this.packagesize = packagesize;
    }

    public String getUpgradetext() {
        return upgradetext;
    }

    public void setUpgradetext(String upgradetext) {
        this.upgradetext = upgradetext;
    }


    public String getMd5() {
        return md5;
    }

    public void setMd5(String md5) {
        this.md5 = md5;
    }


    public String getEnforce() {
        return enforce;
    }

    public void setEnforce(String enforce) {
        this.enforce = enforce;
    }

    public int getVersion_code() {
        return version_code;
    }

    public void setVersion_code(int version_code) {
        this.version_code = version_code;
    }

    @Override
    public int describeContents() {
        return 0;
    }

    @Override
    public void writeToParcel(Parcel dest, int flags) {
        dest.writeString(enforce);
        dest.writeInt(version_code);
        dest.writeString(newversion);
        dest.writeString(downloadurl);
        dest.writeString(packagesize);
        dest.writeString(upgradetext);
        dest.writeString(md5);
    }
}
